# 计科1915班 0306224505 屠玉宝

import random

num = random.randint(1, 100)
# print(num)
print("我已经想好了一个1-100之间的整数，你来猜猜看吧！")

for i in range(5):
    try:
        guess = int(input("请输入你猜的数字："))
        if guess == num:
            print("棒！你猜对了！")
            break
        elif guess > num:
            print("比这个小！")
        else:
            print("比这个大！")
    except Exception as e:
        print("数字不存在")

else:
    print(f"这局你输了！正确的数是{num}")
